package com.example.demo.strategy.CalculationStrategy;

import com.example.demo.enums.CalculationEnum;
import com.example.demo.strategy.CalculationMethodStrategy;
import org.springframework.stereotype.Service;

@Service(value = "StringEqualStrategy")
public class StringEqualStrategy implements CalculationMethodStrategy {
    @Override
    public boolean calculate(String preContent, String value) {
        return preContent.equals(value);
    }

    @Override
    public CalculationEnum getCalculationEnum() {
        return CalculationEnum.STRING_EQUAL;
    }
}
